package test.lambda;


import java.time.LocalDateTime;
import java.time.format.DateTimeFormatter;

@FunctionalInterface
interface InterfaceWithDeafultMethod {

    void aplly(Object obj);

    default void say(String name) {
        System.out.println("hello" + name);
    }
}

public class FunctionalInterfaceWithDefaultMethod {
    public static void main(String[] args) {
        InterfaceWithDeafultMethod i = (o) -> {};
        i.aplly(null);
        i.say("default method");


        String nowDateTime =
                DateTimeFormatter.ofPattern("yyyy/MM/dd HH:ss").format(LocalDateTime.now());
        System.out.println(nowDateTime);
    }
}
